#ifndef IMPLEMENTATIONIW_H
#define IMPLEMENTATIONIW_H

#include <Operation.h>

#include "../../detiq-t/GenericInterface/Widgets/ImageWidgets/ImageWindow.h"
#include "../../detiq-t/GenericInterface/Widgets/ImageWidgets/StandardImageWindow.h"
#include "../../detiq-t/GenericInterface/Widgets/ImageWidgets/DoubleImageWindow.h"

/**
  * Generic for Window
  */

class IWImplementation : public GenericOperation
{
public:
    IWImplementation(QString str);
    virtual void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&)=0;
    bool needCurrentImg() const{return true;}
    bool isValidImgWnd(const genericinterface::ImageWindow* imgWnd) const{return imgWnd!=NULL;}
    virtual ~IWImplementation() {}
};

class iwZoomPlusOp : public IWImplementation
{
public:
    iwZoomPlusOp();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};

class iwZoomMoinsOp : public IWImplementation
{
public:
    iwZoomMoinsOp();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};

class iwApplyMaskOp : public IWImplementation
{
public:
    iwApplyMaskOp();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};

class iwRenameOp : public IWImplementation
{
public:
    iwRenameOp();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>& wndList);
};

class iwPixelGridOp : public IWImplementation
{
public:
    iwPixelGridOp();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};

class iwCropOp : public IWImplementation
{
public:
    iwCropOp();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};

class iwCopyCropOp : public IWImplementation
{
public:
    iwCopyCropOp();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};

/**
  * Specific for standard Window
  */
class SIWImplementation : public GenericOperation
{
public:
    SIWImplementation(QString str);
    virtual void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&)=0;
    bool needCurrentImg() const{return true;}
    bool isValidImgWnd(const genericinterface::ImageWindow* imgWnd) const{return (imgWnd!=NULL)?imgWnd->isStandard():false;}
    virtual ~SIWImplementation() {}
};

class siwHistogramOp : public SIWImplementation
{
public:
    siwHistogramOp();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};

class siwCumulatedHistogramOp : public SIWImplementation
{
public:
    siwCumulatedHistogramOp();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};

class siwHProjectionHistogram : public SIWImplementation
{
public:
    siwHProjectionHistogram();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};

class siwLineProfile : public SIWImplementation
{
public:
    siwLineProfile();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};


class siwColumnProfile : public SIWImplementation
{
public:
    siwColumnProfile();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};


class siwconvertToGrayscale : public SIWImplementation
{
public:
    siwconvertToGrayscale();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};


class siwconvertToBinary : public SIWImplementation
{
public:
    siwconvertToBinary();
    void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&);
};

/**
  * Specific for standard Window
  */
class DIWImplementation : public GenericOperation
{
public:
    DIWImplementation(QString str);
    virtual void operator()(const genericinterface::ImageWindow* currentWnd, const std::vector<const genericinterface::ImageWindow*>&)=0;
    bool needCurrentImg() const{return true;}
    bool isValidImgWnd(const genericinterface::ImageWindow* imgWnd) const{return (imgWnd!=NULL)?imgWnd->isDouble():false;}
    virtual ~DIWImplementation() {}
};
/*
 *There is no implementation nowadays
 */






#endif // IMPLEMENTATIONIW_H
